<?php

/*

 */

/**
 * Description of Db_Newsletter
 *
 * @author ngo
 */
require_once('../../model/Db.php');

class Db_Newsletter extends Db {
    
    public function insert(array $data,$table){
        
        foreach($data as $key => $value)
            $insert[] = $key.'=\''.$value.'\'';
        
        $insert = implode(',',$insert);
        $sql = 'INSERT INTO '.$table.' SET '. $insert;

        return mysql_query($sql);
        
    }
}

?>
